//package com.stock.common;
//
//import org.junit.jupiter.api.Test;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.boot.test.context.SpringBootTest;
//import org.springframework.security.crypto.password.PasswordEncoder;
//
//@SpringBootTest
//public class PasswordEncoderTests {
//    @Autowired
//    PasswordEncoder passwordEncoder;
//
//    @Test
//    public void testEncode(){
//        String encode = passwordEncoder.encode("123456");
//        //$2a$10$1VZ/RkiPJ5NZaWZwFeo2WeM1dh6Rats.GNYCBl5Wtvn2O60/w/1PG
//        System.out.println(encode);
//    }
//
//    @Test
//    public void testDecode(){
//        boolean matches = passwordEncoder.matches("123456", "$2a$10$1VZ/RkiPJ5NZaWZwFeo2WeM1dh6Rats.GNYCBl5Wtvn2O60/w/1PG");
//        // true
//        System.out.println(matches);
//    }
//}
